package com.situ.boot.entity;

import javax.persistence.*;
import java.sql.Timestamp;
import java.util.Objects;

@Entity
@Table(name = "bierorder", schema = "brcc", catalog = "")
public class BierorderEntity {
    private long oid;
    private Long uid;
    private Long did;
    private Double oramont;
    private Double ordimond;
    private Timestamp createtime;
    private String isyx;
    private String iskt;
    private Integer ktnum;

    @Id
    @Column(name = "oid")
    public long getOid() {
        return oid;
    }

    public void setOid(long oid) {
        this.oid = oid;
    }

    @Basic
    @Column(name = "uid")
    public Long getUid() {
        return uid;
    }

    public void setUid(Long uid) {
        this.uid = uid;
    }

    @Basic
    @Column(name = "did")
    public Long getDid() {
        return did;
    }

    public void setDid(Long did) {
        this.did = did;
    }

    @Basic
    @Column(name = "oramont")
    public Double getOramont() {
        return oramont;
    }

    public void setOramont(Double oramont) {
        this.oramont = oramont;
    }

    @Basic
    @Column(name = "ordimond")
    public Double getOrdimond() {
        return ordimond;
    }

    public void setOrdimond(Double ordimond) {
        this.ordimond = ordimond;
    }

    @Basic
    @Column(name = "createtime")
    public Timestamp getCreatetime() {
        return createtime;
    }

    public void setCreatetime(Timestamp createtime) {
        this.createtime = createtime;
    }

    @Basic
    @Column(name = "isyx")
    public String getIsyx() {
        return isyx;
    }

    public void setIsyx(String isyx) {
        this.isyx = isyx;
    }

    @Basic
    @Column(name = "iskt")
    public String getIskt() {
        return iskt;
    }

    public void setIskt(String iskt) {
        this.iskt = iskt;
    }

    @Basic
    @Column(name = "ktnum")
    public Integer getKtnum() {
        return ktnum;
    }

    public void setKtnum(Integer ktnum) {
        this.ktnum = ktnum;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        BierorderEntity that = (BierorderEntity) o;
        return oid == that.oid &&
                Objects.equals(uid, that.uid) &&
                Objects.equals(did, that.did) &&
                Objects.equals(oramont, that.oramont) &&
                Objects.equals(ordimond, that.ordimond) &&
                Objects.equals(createtime, that.createtime) &&
                Objects.equals(isyx, that.isyx) &&
                Objects.equals(iskt, that.iskt) &&
                Objects.equals(ktnum, that.ktnum);
    }

    @Override
    public int hashCode() {
        return Objects.hash(oid, uid, did, oramont, ordimond, createtime, isyx, iskt, ktnum);
    }
}
